import request from '@/utils/request'
// 一体杆列表数据
export function getoneList(params) {
  return request({
    url: '/pole/info/list',
    params
  })
}
// 添加一体杆列表
export function addOneList(data) {
  return request({
    url: `/pole/info`,
    method: 'post',
    data
  })
}
// 编辑一体杆
export function updateOne(data) {
  return request({
      url: `/pole/info`,
      method: 'PUT',
      data
  })
}
// 删除一体杆
export function deleTone(id) {
  return request({
    url: `/pole/info/${id}`,
    method: 'delete'
  })
}
//  封装删除一体杆函数(批量)
export function delOneLists(ids) {
  return requset({
    url:`/pole/info/${ids}`,
    method: 'DELETE'
  })
}
// 告警记录列表
export function getwarnList(params) {
  return request({
    url: '/pole/warning/list',
    params
  })
}
// 查看告警详情
export function getWarnDetail(id) {
  return request({
    url: `/pole/warning/${id}`
  })
}
// 删除告警记录
export function deleteWarn(id) {
  return request({
    url: `/pole/warning/${id}`,
    method: 'delete'
  })
}
